<template>
  <div style="min-height: 300px; border-bottom: 1px solid rgb(240, 240, 240); margin-bottom: 20px">
    <div class="list_th">
      <a-row>
        <a-col span="1" style="padding-left: 8px">
          <a-checkbox :indeterminate="indeterminate" :checked="checkAll" @change="onCheckAllChange"
        /></a-col>
        <a-col v-for="(item, index) in list_th" :key="index" :span="item.span">{{ item.title }} </a-col>
      </a-row>
    </div>
    <a-empty :image="simpleImage" v-show="!pagaData.length" />
    <div class="list_li" v-for="(item, index) in pagaData" :key="index">
      <a-row class="row_head">
        <a-col span="1" style="padding-left: 8px"> <a-checkbox v-model="item.is_checked"/></a-col>
        <a-col span="23">
          <a-icon
            :type="item.order_origin == 0 ? 'link' : item.order_origin == 1 ? 'alipay' : 'mobile'"
            style="margin-right: 10px; color: rgb(203, 204, 206); font-size: 12px"
          />
          <span class="order-num" @dblclick="copyText(item.order_no)">订单号：{{ item.order_no }}</span>
        </a-col>
      </a-row>
      <a-row class="row_goods">
        <a-col span="1" style="padding-left: 8px">
          <a-icon
            :type="item.is_open ? 'minus' : 'plus'"
            class="plusIcon"
            @click="openItem(item)"
            v-show="item.goods_list && item.goods_list.length != 1"
          ></a-icon
        ></a-col>
        <a-col v-for="(inner, index) in list_th" :key="index" :span="inner.span">
          <!-- 产品名称 -->
          <div v-if="inner.title == '产品名称' || inner.title == '商品信息'">
            <a-row
              :gutter="10"
              v-for="(el, inx) in item.is_open ? item.goods_list : [item.goods_list ? item.goods_list[0] : {}]"
              :key="inx"
              style="margin-top: 6px"
            >
              <a-col span="6">
                <img
                  :src="el.goods_pic || el.pic || 'https://cyy-desc.oss-cn-beijing.aliyuncs.com/sp210329_163447.png'"
                  style="width: 80%; border-radius: 5px"
                />
              </a-col>
              <a-col span="18">
                <a-tooltip>
                  <template slot="title">
                    {{ el.name }}
                  </template>
                  <h4 style="color: rgba(0, 0, 0, 0.65);" class="over_e fw_b">{{ el.name }}</h4>
                </a-tooltip>
                <a-tooltip v-if="item.order_type == 0">
                  <template slot="title">
                    {{ el.attr_list ? el.attr_list.map(e => e.attr_name).join() || '默认' : '默认' }}
                  </template>
                  <div class="over_e" style="color: rgba(0, 0, 0, 0.65);">
                    规格：{{ el.attr_list ? el.attr_list.map(e => e.attr_name).join() || '默认' : '默认' }}
                  </div>
                </a-tooltip>
              </a-col>
            </a-row>
          </div>
          <!-- 单价数量 -->
          <div v-if="inner.title == '单价/数量'">
            <div
              v-for="(el, inx) in item.is_open ? item.goods_list : [item.goods_list ? item.goods_list[0] : {}]"
              :key="inx"
            >
              <div class="inner-text-grey">小计：{{ el.total_price }}元</div>
              <div class="inner-text-grey">数量：{{ el.num }}{{ el.unit }}</div>
            </div>
          </div>
          <!-- 运费 -->
          <div v-if="inner.title == '运费'">
            <div v-show="inner.type == 'list' || inner.type == 'offlineList'">
              <div>总金额：{{ item.total_price }}元（运费：{{ item.express_price }}元）</div>
              <div>使用{{ item.integral.forehead_integral }}积分&nbsp;抵扣：{{ item.integral.forehead }}元</div>
            </div>
            <div v-show="inner.type == 'delivery'">
              <div>运费：0.45元</div>
              <div>会员折扣：9.00折</div>
            </div>
          </div>
          <!-- 订单金额 -->
          <div v-if="inner.title == '订单金额'">
            <div class="inner-text-grey">总金额：¥{{ item.total_price }}</div>
            <div class="inner-text-grey">应付款：¥{{ item.pay_price }}</div>
          </div>
          <!-- 订单状态 -->
          <div v-if="inner.title == '订单状态'">
            <div v-if="inner.type == 'refundList'">
              <template v-if="item.refund_status == 0">
                <template v-if="item.is_agree == 1">
                  <template v-if="item.is_user_send == 1">
                    用户已发货
                    <div>快递公司：{{ item.user_send_express }}</div>
                    <div>快递单号：{{ item.user_send_express_no }}</div>
                  </template>
                  <template v-else> 待用户发货 </template>
                </template>
                <template v-else> 待处理 </template>
              </template>
              <template v-else-if="item.refund_status == 1"> 已同意退款退货 </template>
              <template v-else-if="item.refund_status == 2"> 已同意换货 </template>
              <template v-else-if="item.refund_status == 3">
                {{ item.refund_type == 1 ? '已拒绝退货退款' : '已拒换货' }}
                <br />
                <div>{{ item.refund_refuse_desc }}</div>
              </template>
              <template v-if="item.pay_type == 2"> 注：货到付款方式的退款需要线下与客户自行协商 </template>
            </div>
            <div v-else>
              <a-badge :status="orderStatusFormate(item).icon" :text="orderStatusFormate(item).str" />
            </div>
            <div class="inner-text-grey">{{ item.created_at }}</div>
          </div>
          <!-- 订单来源 -->
          <div v-if="inner.title == '订单来源'">
            <div v-if="inner.type == 'refundList'">
              <template v-if="item.platform == 0"> 微信用户 </template>
              <template v-if="item.platform == 1"> 支付宝 </template>
              <template v-if="item.platform == 2"> 公众号 </template>
              <template v-if="item.platform == 3"> APP </template>
            </div>
            <div v-else>{{ item.order_origin | orderOriginFormate }}</div>
          </div>
          <!-- 退款退货/换货 -->
          <div v-if="inner.title == '退款退货/换货'">
            <div>{{ item.refund_type == 1 ? '退款退货' : '换货' }}</div>
          </div>
          <!-- 退款金额 -->
          <div v-if="inner.title == '退款金额'">
            <div>{{ item.refund_price }}元</div>
          </div>
          <!-- 申请理由 -->
          <div v-if="inner.title == '申请理由'">
            <div>{{ item.refund_desc }}</div>
          </div>
          <!-- 实际付款 -->
          <div v-if="inner.title == '实际付款'">
            <div>1299.45元</div>
          </div>
          <!-- 发货方式 -->
          <div v-if="inner.title == '发货方式'">
            <div>快递配送</div>
          </div>
          <!-- 配送状态 -->
          <div v-if="inner.title == '配送状态'">
            <div>已配送</div>
          </div>
          <!-- 配送员 -->
          <div v-if="inner.title == '配送员'">
            <div>无</div>
          </div>
          <!-- 分销情况 -->
          <div v-if="inner.title == '分销情况'">
            <a-row
              style="flex-direction: column; align-items: flex-start"
              v-if="item.bind_share"
            >
              <a-col :span="24">
                <div v-if="item.bind_share.name">临时关系上级：{{ item.bind_share.name }}</div>
                <div v-if="item.bind_share.money">
                  临时关系佣金：<span style="color: red">{{ item.bind_share.money }}</span>元
                </div>
              </a-col>
            </a-row>
            <a-row
              style="flex-direction: column; align-items: flex-start"
              v-if="item.share_1 || item.share_2 || item.share"
            >
              <a-col v-if="item.share && item.first_price" :span="24">
                <div class="inner-text-grey" v-if="item.share.nickname">一级分销商：{{ item.share.nickname }}</div>
                <!-- <div v-if="item.share_1.name">姓名：{{ item.share_1.name }}</div>
                <div v-if="item.share_1.mobile">电话：{{ item.share_1.mobile }}</div> -->
                <div class="inner-text-grey">
                  {{ item.share_send_type == 2 ? '积分' : '佣金' }}：{{ item.first_price }}
                </div>
              </a-col>
              <a-col v-if="item.share_1 && item.second_price" :span="24">
                <div class="inner-text-grey" v-if="item.share_1.nickname">二级分销商：{{ item.share_1.nickname }}</div>
                <!-- <div v-if="item.share_2.name">姓名：{{ item.share_2.name }}</div>
                <div v-if="item.share_2.mobile">电话：{{ item.share_2.mobile }}</div> -->
                <div class="inner-text-grey">
                  {{ item.share_send_type == 2 ? '积分' : '佣金' }}：{{ item.second_price }}
                </div>
              </a-col>
              <a-col v-if="item.share_2 && item.third_price > 0" :span="24">
                <div class="inner-text-grey" v-if="item.share_2.nickname">三级分销商：{{ item.share_2.nickname }}</div>
                <!-- <div v-if="item.share_3.name">姓名：{{ item.share_3.name }}</div>
                <div v-if="item.share_3.mobile">电话：{{ item.share_3.mobile }}</div> -->
                <div class="inner-text-grey">
                  {{ item.share_send_type == 2 ? '积分' : '佣金' }}：{{ item.third_price }}
                </div>
              </a-col>
              <a-col v-if="item.bind_share" :span="24">
                <div class="inner-text-grey" v-if="item.bind_share.name">订单佣金：{{ item.bind_share.name }}</div>
                <!-- <div v-if="item.share_3.name">姓名：{{ item.share_3.name }}</div>
                <div v-if="item.share_3.mobile">电话：{{ item.share_3.mobile }}</div> -->
                <div class="inner-text-grey">
                  {{ item.share_send_type == 2 ? '积分' : '佣金' }}：{{ item.bind_share.money }}
                </div>
              </a-col>

            </a-row>
            <div v-else>
              自购返利<span style="color: red">{{ item.rebate }}</span
              >元
            </div>
          </div>
          <!-- 操作 -->
          <div v-if="inner.title == '操作'" style="" class="row_actions">
            <div v-if="inner.type == 'refundList'">
              <template v-if="item.is_user_cancel == 0">
                <template v-if="item.refund_status == 0">
                  <template v-if="item.refund_type == 1">
                    <template v-if="item.is_agree == 1">
                      <template v-if="item.is_user_send != 1">
                        <a-button
                          type="link"
                          v-if="inner.actions.find(sm => sm == '拒绝退货')"
                          @click="$emit('triggerAction', 'disagree_2', item)"
                        >
                          拒绝退货
                        </a-button>
                        <a-divider type="vertical" />
                      </template>
                      <a-button
                        type="link"
                        v-if="inner.actions.find(sm => sm == '确认收货')"
                        @click="$emit('triggerAction', 'agree_3', item)"
                      >
                        确认收货
                      </a-button>
                    </template>
                    <template v-else>
                      <a-button
                        type="link"
                        v-if="inner.actions.find(sm => sm == '同意退货')"
                        @click="$emit('triggerAction', 'agree_2', item)"
                      >
                        同意退货
                      </a-button>
                      <a-divider type="vertical" v-if="inner.actions.find(sm => sm == '同意退货')" />
                      <a-button
                        type="link"
                        v-if="inner.actions.find(sm => sm == '拒绝退货')"
                        @click="$emit('triggerAction', 'disagree_2', item)"
                      >
                        拒绝退货
                      </a-button>
                    </template>
                  </template>
                  <template v-else>
                    <a-button
                      type="link"
                      v-if="inner.actions.find(sm => sm == '同意换货')"
                      @click="$emit('triggerAction', 'agree_1', item)"
                    >
                      同意换货
                    </a-button>
                    <a-divider type="vertical" v-if="inner.actions.find(sm => sm == '同意换货')" />
                    <a-button
                      type="link"
                      v-if="inner.actions.find(sm => sm == '拒绝换货')"
                      @click="$emit('triggerAction', 'disagree_1', item)"
                    >
                      拒绝换货
                    </a-button>
                  </template>
                </template>
              </template>
              <template v-else> 用户取消售后申请 </template>
            </div>
            <div v-else>
              <template v-if="item.md_id > 0">
                <a-button
                  type="link"
                  v-if="item.apply_delete == 1 && list_th[0].type != 'shareOrder' && item.trade_status != 1"
                  @click="$emit('triggerAction', 'order_cancel_1', item, '')"
                  :disabled="item.is_trans != 1"
                  >同意</a-button
                >
                <a-button
                  type="link"
                  v-if="
                    inner.actions.find(sm => sm == '发货') &&
                      item.apply_delete != 1 &&
                      (item.trade_status == 0 || (item.pay_type == 2 && item.trade_status == 0)) &&
                      item.is_delete == 0 &&
                      !item.delivery_id
                  "
                  @click="$emit('triggerAction', 'order_send', item)"
                  :disabled="item.is_trans != 1"
                >
                  发货
                </a-button>
                <a-button
                  type="link"
                  v-if="
                    inner.actions.find(sm => sm == '核销') &&
                      (item.is_pay == 1 || item.pay_type == 2) &&
                      item.apply_delete != 1 &&
                      item.is_offline == 1 &&
                      item.trade_status < 1 &&
                      item.is_delete == 0
                  "
                  @click="$emit('triggerAction', 'order_cancel_verification', item)"
                  :disabled="item.is_trans != 1"
                >
                  核销
                </a-button>
                <a-button
                  type="link"
                  v-if="inner.actions.find(sm => sm == '确认收货') && item.pay_type == 2 && item.trade_status == 2"
                  @click="$emit('triggerAction', 'order_confirm', item)"
                  :disabled="item.is_trans != 1"
                >
                  收货
                </a-button>
                <a-button
                  type="link"
                  v-if="inner.actions.find(sm => sm == '编辑') && item.trade_status != 0"
                  @click="$emit('triggerAction', 'order_edit', item)"
                >
                  详情
                </a-button>
                <a-divider type="vertical" />
                <a-dropdown v-if="inner.actions.length" :disabled="item.is_trans != 1">
                  <a-button type="link"> 更多 <a-icon type="down" /> </a-button>
                  <a-menu slot="overlay">
                    <a-menu-item
                      v-if="
                        inner.actions.find(sm => sm == '发货') &&
                          item.apply_delete == 1 &&
                          (item.trade_status == 0 || (item.pay_type == 2 && item.trade_status == 0)) &&
                          item.is_delete == 0 &&
                          !item.delivery_id
                      "
                      :disabled="item.is_trans != 1"
                    >
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_send', item)"> 发货 </a>
                    </a-menu-item>
                    <a-menu-item
                      type="link"
                      v-if="
                        inner.actions.find(sm => sm == '核销') &&
                          (item.is_pay == 1 || item.pay_type == 2) &&
                          item.apply_delete == 1 &&
                          item.is_offline == 1 &&
                          item.trade_status < 1 &&
                          item.is_delete == 0
                      "
                      :disabled="item.is_trans != 1"
                    >
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_cancel_verification', item)">
                        核销
                      </a>
                    </a-menu-item>
                    <a-menu-item
                      v-if="inner.actions.find(sm => sm == '取消') && item.trade_status < 1 && item.is_delete == 0"
                    >
                      <a-popconfirm placement="left" @confirm="$emit('triggerAction', 'order_cancel', item, reason)">
                        <template slot="title">
                          <p>确认取消该订单吗？</p>
                          <a-input v-model="reason" placeholder="请输入取消原因" />
                        </template>
                        <a href="javascript:;"> 取消 </a>
                      </a-popconfirm>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '编辑') && item.trade_status == 0">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_edit', item)"> 详情 </a>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '订单打印')">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_print', item)">订单打印</a>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '小票打印')">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_receipts_print', item)">小票打印</a>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '添加备注')">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_remark', item)">添加备注</a>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '移入回收站')">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_recycle', item)">移入回收站</a>
                    </a-menu-item>
                  </a-menu>
                </a-dropdown>
              </template>
              <template v-else>
                <a-button
                  type="link"
                  v-if="item.apply_delete == 1 && list_th[0].type != 'shareOrder' && item.trade_status != 1"
                  @click="$emit('triggerAction', 'order_cancel_1', item, '')"
                >
                  同意
                </a-button>
                <a-button
                  type="link"
                  v-if="
                    inner.actions.find(sm => sm == '发货') &&
                      item.apply_delete != 1 &&
                      (item.trade_status == 0 || (item.pay_type == 2 && item.trade_status == 0)) &&
                      item.is_delete == 0 &&
                      item.is_offline != 1 &&
                      !item.delivery_id
                  "
                  @click="$emit('triggerAction', 'order_send', item)"
                >
                  发货
                </a-button>
                <a-button
                  type="link"
                  v-if="
                    inner.actions.find(sm => sm == '核销') &&
                      (item.is_pay == 1 || item.pay_type == 2) &&
                      item.is_offline == 1 &&
                      item.apply_delete != 1 &&
                      item.trade_status < 1 &&
                      item.is_delete == 0
                  "
                  @click="$emit('triggerAction', 'order_cancel_verification', item)"
                >
                  核销
                </a-button>
                <a-button
                  type="link"
                  v-if="inner.actions.find(sm => sm == '确认收货') && item.pay_type == 2 && item.trade_status == 2"
                  @click="$emit('triggerAction', 'order_confirm', item)"
                >
                  收货
                </a-button>
                <a-button
                  type="link"
                  v-if="inner.actions.find(sm => sm == '编辑') && item.trade_status != 0"
                  @click="$emit('triggerAction', 'order_edit', item)"
                >
                  详情
                </a-button>
                <a-divider type="vertical" />
                <a-dropdown v-if="inner.actions.length">
                  <a-button type="link"> 更多 <a-icon type="down" /> </a-button>
                  <a-menu slot="overlay">
                    <a-menu-item
                      v-if="
                        inner.actions.find(sm => sm == '发货') &&
                          item.apply_delete == 1 &&
                          (item.trade_status == 0 || (item.pay_type == 2 && item.trade_status == 0)) &&
                          item.is_delete == 0 &&
                          item.is_offline != 1 &&
                          !item.delivery_id
                      "
                    >
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_send', item)">发货</a>
                    </a-menu-item>
                    <a-menu-item
                      type="link"
                      v-if="
                        inner.actions.find(sm => sm == '核销') &&
                          (item.is_pay == 1 || item.pay_type == 2) &&
                          item.is_offline == 1 &&
                          item.apply_delete == 1 &&
                          item.trade_status < 1 &&
                          item.is_delete == 0
                      "
                    >
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_cancel_verification', item)">核销</a>
                    </a-menu-item>
                    <a-menu-item
                      v-if="inner.actions.find(sm => sm == '取消') && item.trade_status < 1 && item.is_delete == 0"
                    >
                      <a-popconfirm placement="left" @confirm="$emit('triggerAction', 'order_cancel', item, reason)">
                        <template slot="title">
                          <p>确认取消该订单吗？</p>
                          <a-input v-model="reason" placeholder="请输入取消原因" />
                        </template>
                        <a href="javascript:;"> 取消 </a>
                      </a-popconfirm>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '编辑') && item.trade_status == 0">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_edit', item)"> 详情 </a>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '订单打印')">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_print', item)">订单打印</a>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '小票打印')">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_receipts_print', item)">小票打印</a>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '添加备注')">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_remark', item)">添加备注</a>
                    </a-menu-item>
                    <a-menu-item v-if="inner.actions.find(sm => sm == '移入回收站')">
                      <a href="javascript:;" @click="$emit('triggerAction', 'order_recycle', item)">移入回收站</a>
                    </a-menu-item>
                  </a-menu>
                </a-dropdown>
              </template>
            </div>
          </div>
          <!-- 买家/收货人 -->
          <div v-if="inner.title == '买家/收货人'">
            <!-- <a-tooltip v-for="(el, inx) in item.goods_list" :key="inx"> -->
            <!-- <template slot="title">
                <div class="addressInfo">
                  <span>姓名:{{ item.name }}</span>
                  <span>手机:{{ item.mobile }}</span>
                  <span>地址:{{ item.address }}</span>
                </div>
              </template> -->
            <div class="delivery_type">
              <span>{{ item.name }}</span>
              <span>{{
                item.delivery_type == 0 ? '快递配送' : item.delivery_type == 1 ? '商店自提' : '同城配送'
              }}</span>
            </div>
            <!-- </a-tooltip> -->
          </div>
          <!-- 下单门店/时间 -->
          <div v-if="inner.title == '下单门店/时间'">
            <div v-if="item.md_info" class="md_info">
              <span>{{ item.md_info.name }}</span>
              <span>{{ item.created_at }}</span>
            </div>
            <span v-else>/</span>
          </div>
          <!-- 佣金状态/时间 -->
          <div v-if="inner.title == '佣金状态/时间'">
            <div class="cashStatus">
              <span>分销状态:{{ item.is_price == 0 ? '待入账' : '已入账' }}</span>
              <span
                >到账时间:{{
                  item.confirm_time > 0 ? $moment(item.confirm_time * 1000).format('YYYY-MM-DD HH:mm:ss') : '-'
                }}</span
              >
            </div>
          </div>
        </a-col>
      </a-row>
    </div>
  </div>
</template>

<script>
import { Empty } from 'ant-design-vue'
export default {
  props: {
    list_th: {
      type: Array,
      default: () => []
    },
    pagaData: {
      type: Array,
      default: () => []
    }
  },
  data() {
    return {
      reason: ''
    }
  },
  filters: {
    orderTypeFilter(val) {
      switch (val) {
        case '0':
          return '商城订单'
        case '1':
          return '酒店预约'
        case '2':
          return '服务预约'
        default:
          return ''
      }
    },

    payTypeFormate(val) {
      switch (val) {
        case '1':
          return '微信支付'
        case '2':
          return '货到付款'
        case '3':
          return '余额'
        case '4':
          return '支付宝'
        default:
          return '未支付'
      }
    },
    orderOriginFormate(val) {
      switch (val) {
        case '1':
          return '公众号或网络'
        case '2':
          return 'app'
        case '3':
          return '小程序'
        default:
          return ''
      }
    }
  },
  computed: {
    indeterminate() {
      let len = this.pagaData.filter(item => item.is_checked).length
      if (len && len != this.pagaData.length) {
        return true
      } else {
        return false
      }
    },
    checkAll() {
      let len = this.pagaData.filter(item => item.is_checked).length
      if (len == this.pagaData.length && this.pagaData.length != 0) {
        return true
      } else {
        return false
      }
    }
  },
  watch: {},
  beforeCreate() {
    this.simpleImage = Empty.PRESENTED_IMAGE_SIMPLE
  },
  created() {},
  mounted() {},
  updated() {},
  methods: {
    orderStatusFormate(val) {
      let str = '',
        icon = 'success'
      if (val.is_pay == 0) {
        str = '未支付'
        icon = 'default'
      }
      if (val.is_pay == 1 && val.trade_status == 0) {
        str = '待发货'
        icon = 'warning'
      }
      if (val.is_pay == 1 && val.trade_status == 2) {
        str = '待收货'
        icon = 'warning'
      }
      if (val.is_pay == 1 && val.trade_status == 3) {
        str = '已完成'
        icon = 'success'
      }
      return { str, icon }
    },
    onCheckAllChange(e) {
      let len = this.pagaData.filter(item => item.is_checked).length
      if (len != this.pagaData.length) {
        this.pagaData.forEach(el => {
          this.$set(el, 'is_checked', true)
        })
      } else {
        this.pagaData.forEach(el => {
          this.$set(el, 'is_checked', false)
        })
      }
    },
    openItem(item) {
      if (typeof item.is_open == 'undefined') {
        this.$set(item, 'is_open', true)
        return
      }
      this.$set(item, 'is_open', !item.is_open)
    },
    copyText(data) {
      if (!data) return
      this.$copyText(data)
        .then(e => {
          this.$message.success('复制成功')
        })
        .catch(err => {
          console.log(err)
          this.$message.error('复制失败')
        })
    }
  }
}
</script>

<style scoped lang="less">
.plusIcon {
  cursor: pointer;
  transition: all 0.5s;
  &:hover {
    color: rgb(24, 144, 255);
  }
}
.fw_b {
  font-weight: bold;
}
.row_footer {
  border-top: 1px solid rgb(240, 240, 240);
  color: rgba(143, 143, 143);
  line-height: 50px;
}
.row_actions {
  display: flex;
  align-items: center;
  /deep/ .ant-btn {
    padding: 0;
  }
}
.list_li {
  /deep/.ant-row {
    display: flex;
    align-items: center;
  }
  .row_goods {
    transition: all 0.5s;
  }
  .row_footer {
    transition: all 0.5s;
  }
  &:hover {
    .row_head {
      background: rgb(230, 247, 255);
    }
    .row_goods {
      background: rgb(230, 247, 255);
    }
    .row_footer {
      background: rgb(230, 247, 255);
    }
  }
}
.list_li:hover {
  background: rgb(230, 247, 255);
}
.row_goods {
  padding: 15px 0;
}
.over_e {
  width: 80%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.list_th {
  background: rgb(250, 250, 250);
  height: 50px;
  line-height: 50px;
  color: black;
}
.row_head {
  background: rgb(250, 251, 253);
  border-top: 1px solid rgb(240, 240, 240);
  padding: 10px 0;
  color: rgba(143, 143, 143);

  .order-num {
    user-select: none;
  }
}
.delivery_type {
  display: flex;
  flex-direction: column;
  font-size: 14px;
  color: rgba(0, 0, 0, 0.45);
  margin: 5px 0;
}
.addressInfo {
  display: flex;
  flex-direction: column;
  font-size: 12px;
  color: #fff;
}
.md_info {
  display: flex;
  flex-direction: column;
  font-size: 14px;
  color: rgba(0, 0, 0, 0.45);
  span {
    margin: 5px 0;
  }
}

.inner-text-grey {
  font-size: 14px;
  font-family: PingFang SC;
  font-weight: 400;
  line-height: 22px;
  color: rgba(0, 0, 0, 0.45);
}
.cashStatus {
  display: flex;
  flex-direction: column;
  font-size: 14px;
  color: rgba(0, 0, 0, 0.45);
}
</style>
